<?php 
/**
 * @version        $Id$
 * @author         master@xuewl.com
 * @copyright      Copyright (c) 2007 - 2014, Chongqing xuewl Information Technology Co., Ltd.
 * @link           http://www.xuewl.com
**/
namespace Document\Api;
class PlatformApi 
{
	private static $handler    =   '';
	public static function init($type) {
        $type 	= (empty($type)) ? 'meeduo' : $type;  
        $class 	= strpos($type,'\\') ? $type : 'Document\\Api\\Driver\\'. ucwords(strtolower($type));
		self::$handler  =    $class;
	}

	public static function callback($type, $param) {
        if(empty(self::$handler)){
            self::init($type);
        }
        $class  =   self::$handler;
        return $class::callback($param);          
	}

}